package com.lms.service;

import com.lms.bean.RentRecord;
import com.lms.bean.RentRecordQuery;
import com.lms.util.QueryResult;
import com.lms.vo.RentRecordVO;

import java.util.List;

public interface RentRecordService {

    Long getTotalCount();

    Long getTotalCount(Long rentId);

    List<RentRecordVO> findAll(int page, int pageSize);

    List<RentRecordVO> findAll(int page, int pageSize,Long rentId);


    RentRecord getLastOne();

    List<RentRecord> findAll();


    void save(RentRecord rentRecord);

    RentRecord findById(Long rentId);

    void delete(Long rentId);

    void deleteAll(List<Long> ids);

    QueryResult<RentRecordVO> queryByBookNameLikeOrUsernameLikeOrState(int page, int pageSize, RentRecordQuery param);

    RentRecord findBy(Long userId, Long bookId);
}
